#define BASE_STRUCT(memberp, struct_type, member_name) \
((struct_type *)((char *)(memberp) - offsetof(struct_type, member_name)))
+typedef enum {
+ fix_unknown=-1,
+ fix_none=0,
+ fix_2d=1,
+ fix_3d,
+ fix_dgps,
+ fix_pps
+} fix_type;
/*
* Define globally on which kind of data gpsbabel is working.
rtedata
} gpsdata_type;
-typedef enum {
- fix_unknown=-1,
- fix_none=0,
- fix_2d=1,
- fix_3d,
- fix_dgps,
- fix_pps
-} fix_type;
-
#define NOTHINGMASK 0
#define WPTDATAMASK 1
#define TRKDATAMASK 2
unsigned short cet_converted; /* strings are converted to UTF8; interesting only for input */
} route_head;
+/*
+ * Structure of recomputed track/roue data.
+ */
+typedef struct {
+ double distance_meters;
+ double max_alt;
+ double min_alt;
+ double max_spd;
+ double min_spd;
+ time_t start; /* Min time */
+ time_t end; /* Max time */
+} computed_trkdata;
+
/*
* Bounding box information.
*/
void track_restore( queue *head_bak);
void track_append( queue *src );
void route_flush( queue *head );
-void track_recompute( const route_head *trk);
+void track_recompute( const route_head *trk, computed_trkdata **);
/*
* All shortname functions take a shortname handle as the first arg.